﻿using System;
using System.Collections.Generic;
using FluentNHibernate.Mapping;
using EntitiesAndMappings.Entities;

namespace EntitiesAndMappings.Mappings
{
    public class TipoMovimientoMap : ClassMap<TipoMovimiento>
    {
        public TipoMovimientoMap()
        {
            Id(x => x.Id).GeneratedBy.Native();
            Map(x => x.Codigo).Length(14).Unique().Not.Nullable();
            Map(x => x.Descripcion).Length(100).Not.Nullable();
            Map(x => x.TipoEntradaOSalida).Not.Nullable();
            Map(x => x.EntregaAPersonal).Not.Nullable();
            Map(x => x.Mantenimiento).Not.Nullable();
            Map(x => x.Estado).Length(1).Not.Nullable();
        }
    }
}
